References to Applications
You can use this form to refer to any application:
application applicationNameString ¬ [ of machine computerName [ of zone AppleTalkZoneName ] ]whereapplicationNameString is either a string of the form
"Disk:Folder1:Folder2:
that specifies where the application is stored on the
...:ApplicationName"
local computer or a string that consists of the name of the application. Disk specifies the disk on the local computer on which the application is stored, Folder1:Folder2:...
specifies the sequence of folders that you would have to open to find the application on the local computer, and ApplicationName specifies the name of the application. If it is located on a remote computer, the application must be running and applicationNameString must be the name of the application as listed in the Application menu on that computer. AppleScript doesn't distinguish uppercase letters from lowercase letters in application names.computerName (a string) is the Macintosh Name assigned in the Sharing
Setup control panel of the computer on which the specified application is running. This portion of the reference is required if the application is located
on a remote computer.AppleTalkZoneName (a string) is the name of the zone, if any, in which the specified remote computer is located. The name must appear in the list of AppleTalk Zones displayed in the Chooser.
After a script is compiled, a reference to an application on the local computer identifies the application no matter where it is located on that computer.
This behavior resembles the behavior of an alias. However, a reference to
an application on a remote computer won't compile unless the application
is running and several other conditions are met; see "References to Remote Applications" on page 149 for details.The actions you can perform on a specific application depend on the way
the application that created the file defines an application object. AppleScript always locates the application as described in the sections that follow, but uses the definition in the application's dictionary to determine the characteristics
of the object, such as its properties and the commands it can handle. For the Scriptable Text Editor's definition of an application, see page 318.
Subtopics
- References to Local Applications
- References to Remote Applications